home *** CD-ROM | disk | FTP | other *** search
/ ShareWare OnLine 2 / ShareWare OnLine Volume 2 (CMS Software)(1993).iso / hobby / golftrac.zip / LO171.DOC < prev    next >
Text File  |  1990-11-17  |  43KB  |  907 lines

  1.  
  2.  
  3.  
  4.            LL         OOOOOO    GGGGGG    OOOOOO   UU    UU  TTTTTTTT
  5.            LL        OO    OO  GG    GG  OO    OO  UU    UU     TT
  6.            LL        OO    OO  GG        OO    OO  UU    UU     TT
  7.            LL        OO    OO  GG        OO    OO  UU    UU     TT
  8.            LL        OO    OO  GG  GGGG  OO    OO  UU    UU     TT
  9.            LL    LL  OO    OO  GG    GG  OO    OO  UU    UU     TT
  10.            LLLLLLLL   OOOOOO    GGGGGG    OOOOOO    UUUUUU      TT
  11.  
  12.  
  13.        Copyright (c) 1988-1990 Byte_Magic Software.  All rights reserved.
  14.  
  15.  
  16.                                   Version 1.71
  17.  
  18.  
  19.  
  20.                                   Greg Messer
  21.  
  22.                               Byte_Magic Software
  23.  
  24.                             9850 Meadowglen Ln.  #35
  25.  
  26.                              Houston, Texas  77042
  27.  
  28.                                 (713) 975-9033
  29.  
  30.  
  31.  
  32.         Table of Contents
  33.         ───────────────────────────────────────────────────────────────
  34.  
  35.                       LogOut Overview ........................ Page  1
  36.  
  37.                       Usage and Parameters ................... Page  2
  38.  
  39.                       The Time Limit ......................... Page  3
  40.  
  41.                       The Keystroke File ..................... Page  4
  42.  
  43.                       The Current Keystroke ID ............... Page  5
  44.  
  45.                       The Repeat Mode ........................ Page  6
  46.  
  47.                       The Immediate Mode ..................... Page  7
  48.  
  49.                       The Include and Exclude Device Lists ... Page  8
  50.  
  51.                       Combinations of Parameters ............. Page  9
  52.  
  53.                       Keystroke File Structure ............... Page 10
  54.  
  55.                       General Hints .......................... Page 11
  56.  
  57.                       Technical Information .................. Page 12
  58.  
  59.                       Sample Keystroke File ............... Appendix A
  60.  
  61.                       Interrupt 61h Services .............. Appendix B
  62.  
  63.                       Packing List ........................ Appendix C
  64.  
  65.  
  66.  
  67.         LogOut Overview                                          Page 1
  68.         ───────────────────────────────────────────────────────────────
  69.  
  70.  
  71.                       LogOut (LO.COM) is a memory resident program
  72.                       designed to send keystrokes to the keyboard
  73.                       buffer of a PC after a specified period of
  74.                       inactivity has been exceeded.
  75.  
  76.                       When LogOut sends the keystrokes, the result is
  77.                       the same as if someone were typing the keys at
  78.                       the keyboard.  The application cannot tell the
  79.                       difference.  The only exceptions to this are
  80.                       programs that move the keyboard buffer.
  81.  
  82.                       "Inactivity" is defined here as no keyboard,
  83.                       disk, screen or printer activity.  If no one is
  84.                       typing and the disk drives, screen and printer
  85.                       are not being used, the system is considered to
  86.                       be inactive.  This definition of inactivity is
  87.                       configurable as explained below in the section on
  88.                       the 'N' and 'X' command line parameters.
  89.  
  90.                       LogOut is installed in memory the first time it
  91.                       is run and the installed portion is simply
  92.                       updated on each subsequent run.  Although it
  93.                       cannot remove itself from memory, LogOut can be
  94.                       disabled at any time by specifying a time limit
  95.                       of 0, as explained below in the section on the
  96.                       'T' command line parameter.  LogOut normally uses
  97.                       less than 1024 bytes of memory after
  98.                       installation.  This depends on the size of the
  99.                       environment at load time - more about this later
  100.                       in the general hints section.
  101.  
  102.                       Each time it is run, LogOut needs to know how
  103.                       long to wait, what keys to send when the time
  104.                       limit is up, and other things.  This information
  105.                       is supplied on the command line.
  106.  
  107.                       In the rest of this documentation, LogOut will be
  108.                       explained in increasing detail.  First, the basic
  109.                       usage of LogOut will be shown, and the command
  110.                       line parameters will be briefly described.  Then
  111.                       each command line parameter will be described in
  112.                       detail, followed by a discussion of the
  113.                       interactions of the parameters when used in
  114.                       combination.  Finally, the technical foundations
  115.                       of LogOut will be explained for those who would
  116.                       like to add to the capabilities of the program.
  117.  
  118.                       LogOut was originally written in 1988 as a
  119.                       network security program to back users out of any
  120.                       application when they were not working or were
  121.                       possibly no longer at their desks; hence the
  122.                       name.  LogOut has grown in capability since then,
  123.                       and a little experimentation will reveal many
  124.                       uses for this unique program.
  125.  
  126.  
  127.  
  128.         Usage and Parameters                                     Page 2
  129.         ───────────────────────────────────────────────────────────────
  130.  
  131.  
  132.              Usage:   LO [T=mmm] [F=filename.ext] [C=ID] [R=(yn)]
  133.  
  134.                          [I=(yn)] [N=device] [X=device] [?]
  135.  
  136.  
  137.               T=mmm   This is the Time in minutes of inactivity before
  138.                       keys are sent.  The default time limit is 30
  139.                       minutes.  On each run, the time limit is left as
  140.                       is unless a new time is entered.  Entering T=0
  141.                       disables LogOut until a new time is entered.
  142.  
  143.          F=filename   This is the Filename of the keystroke file.  The
  144.                       default filename is 'LOGOUT.DAT'.  Drive and path
  145.                       may be included, up to 127 characters.
  146.  
  147.              C=ID     This is the Current keystroke ID.  The default
  148.                       current keystroke ID is 'DEF'.  Uppercase and
  149.                       lowercase characters are NOT considered equal.
  150.  
  151.              R=(yn)   This is the Repeat mode setting, and can be 'Y',
  152.                       'y', 'N', or 'n'.  'Y' means repeat the keys
  153.                       after each time period of activity passes.  'N'
  154.                       is the default, keys are only sent once, then
  155.                       LogOut must be run again to reset the timer and
  156.                       reenable LogOut.
  157.  
  158.              I=(yn)   This is the Immediate mode setting, and can be
  159.                       'Y', 'y', 'N', or 'n'.  'Y' means stuff the
  160.                       keyboard immediately.  'N' is the default, keys
  161.                       are not sent immediately.
  162.  
  163.              N=dev.   This is the iNcluded device list.  The specified
  164.                       devices are included for activity watching.
  165.                       Valid entries for 'dev.' are D, K, P and S for
  166.                       Disk, Keyboard, Printer and Screen respectively.
  167.  
  168.              X=dev.   This is the eXcluded device list.  The specified
  169.                       devices are excluded from activity watching.
  170.                       Valid entries for 'dev.' are D, K, P and S for
  171.                       Disk, Keyboard, Printer and Screen respectively.
  172.  
  173.              ?        This is the Help parameter.  When '?' is entered
  174.                       on the command line a help screen will be shown.
  175.                       The installed state of LogOut will be unchanged.
  176.                       Entering 'H' or 'h', or no parameters at all,
  177.                       will also produce the help screen.
  178.  
  179.                       Parameters may be entered in upper or lower case.
  180.                       Only the keystroke ID is case-sensitive.
  181.  
  182.                       Invalid or unsupported parameters will cause
  183.                       LogOut to be disabled, for safety.  Messages will
  184.                       be displayed to signal any errors.
  185.  
  186.  
  187.  
  188.         The Time Limit                                           Page 3
  189.         ───────────────────────────────────────────────────────────────
  190.  
  191.                          ┌─────────┐
  192.                       LO │ [T=mmm] │ [F=filename.ext] [C=ID] [R=(yn)]
  193.                          └─────────┘
  194.  
  195.                          [I=(yn)] [N=device] [X=device] [?]
  196.  
  197.  
  198.                       The time parameter tells LogOut the maximum
  199.                       period of inactivity, in minutes, that can pass
  200.                       before timeout occurs.  After that time period
  201.                       expires the keystrokes are sent to the PC's
  202.                       keyboard buffer.
  203.  
  204.                       For example, entering T=25 tells LogOut to wait
  205.                       for 25 minutes of inactivity to pass before
  206.                       sending keystrokes.
  207.  
  208.                       The default time limit of 30 minutes is used
  209.                       if the time limit is not specified on the first
  210.                       run.  The time limit remains the same on
  211.                       subsequent runs unless specifically reset.  Once
  212.                       the time limit is changed, it will remain the
  213.                       same until it is changed again.
  214.  
  215.                       Entering "T=0" will disable LogOut until the time
  216.                       is reset.  Subsequent runs that do not specify a
  217.                       time limit, zero or otherwise, will set the time
  218.                       back to the default 30 minutes.
  219.  
  220.                       LogOut may be installed with "T=0" on the first
  221.                       run in order to get it loaded early without it
  222.                       being enabled.
  223.  
  224.                       The maximum time limit is 65,535 minutes,
  225.                       specified as T=65535.  This is 1,092 hours and
  226.                       fifteen minutes, or about 45 and one half days,
  227.                       which should be plenty.
  228.  
  229.                       If the time limit specified on the command line
  230.                       is non-numeric, LogOut will be disabled and an
  231.                       error message will be displayed.
  232.  
  233.  
  234.  
  235.         The Keystroke File                                       Page 4
  236.         ───────────────────────────────────────────────────────────────
  237.  
  238.                                  ┌──────────────────┐
  239.                       LO [T=mmm] │ [F=filename.ext] │ [C=ID] [R=(yn)]
  240.                                  └──────────────────┘
  241.  
  242.                          [I=(yn)] [N=device] [X=device] [?]
  243.  
  244.  
  245.                       The keystroke file parameter tells LogOut where
  246.                       to find the keystrokes to be sent upon timeout.
  247.  
  248.                       The default keystroke file is LOGOUT.DAT.  If
  249.                       another file contains the desired key codes, then
  250.                       the F=filename.ext parameter tells LogOut to use
  251.                       that file.  Be aware that LogOut must read a
  252.                       keystroke file in order to change the current
  253.                       keystrokes to be sent.  If a new current
  254.                       keystroke ID is specified on the command line and
  255.                       another data file is being used, you must also
  256.                       specify that filename.  LogOut will not
  257.                       automatically look for the previously used
  258.                       keystroke file.
  259.  
  260.                       The maximum keystroke file size is 10,240 bytes.
  261.  
  262.                       The keystroke file contains keystroke IDs and
  263.                       their corresponding key codes as shown below:
  264.  
  265.                            ID=aaa,sss,[aaa,sss,aaa,sss,...],255
  266.  
  267.                       The "ID" term is the current keystroke's ID.
  268.                       This ID represents the keys to be sent upon
  269.                       timeout while inside a particular program or
  270.                       during a particular situation.
  271.  
  272.                       The "aaa,sss" terms are the ASCII and scan code
  273.                       pairs for each key to be sent when the time limit
  274.                       is reached.
  275.  
  276.                       The '255' is required to mark the end of a line.
  277.                       (This is changed from earlier versions of LogOut
  278.                       which used a '4' for end-of-line.)
  279.  
  280.                       If the keystroke file specified on the command
  281.                       line is not found or an I/O error occurs, LogOut
  282.                       will be disabled and an error message will be
  283.                       displayed.
  284.  
  285.                       Appendix A is a sample keystroke file.
  286.  
  287.  
  288.  
  289.         The Current Keystroke ID                                 Page 5
  290.         ───────────────────────────────────────────────────────────────
  291.  
  292.                                                   ┌────────┐
  293.                       LO [T=mmm] [F=filename.ext] │ [C=ID] │ [R=(yn)]
  294.                                                   └────────┘
  295.  
  296.                          [I=(yn)] [N=device] [X=device] [?]
  297.  
  298.  
  299.                       The current keystroke ID tells LogOut which
  300.                       keystroke sequence in the keystroke file to send
  301.                       upon timeout.
  302.  
  303.                       The default current keystroke ID is "DEF".  If a
  304.                       filename is specified on the command line and a
  305.                       current keystroke ID is not, then LogOut will
  306.                       look for "DEF" in the specified file.  LogOut
  307.                       will not automatically look for the previously
  308.                       used current keystroke ID.
  309.  
  310.                       The term "ID" must exactly match an ID in the
  311.                       keystroke file, and the ID comparison is case
  312.                       sensitive.  For example, 'pgm1' is NOT equal to
  313.                       'PGM1'.  The ID of the current keystroke sequence
  314.                       may be up to 31 characters in length.
  315.  
  316.                       Each keystroke sequence must have a unique ID for
  317.                       LogOut to work.  If two situations share the same
  318.                       ID, LogOut will only use the first occurrence of
  319.                       that ID in the file, ignoring all others.  If
  320.                       there is no way to avoid duplicate IDs, then put
  321.                       one in uppercase letters and the other in
  322.                       lowercase.  This is enough to differentiate the
  323.                       two IDs.
  324.  
  325.                       If the current keystroke ID specified on the
  326.                       command line does not occur in the keystroke
  327.                       file, LogOut will be disabled and an error
  328.                       message will be displayed.
  329.  
  330.  
  331.  
  332.         The Repeat Mode                                          Page 6
  333.         ───────────────────────────────────────────────────────────────
  334.  
  335.                                                          ┌──────────┐
  336.                       LO [T=mmm] [F=filename.ext] [C=ID] │ [R=(yn)] │
  337.                                                          └──────────┘
  338.  
  339.                          [I=(yn)] [N=device] [X=device] [?]
  340.  
  341.  
  342.                       The Repeat mode parameter tells LogOut whether to
  343.                       send the keys after every timeout period until
  344.                       activity resumes, or to only send the keys once,
  345.                       then stop.  The argument for the repeat mode can
  346.                       be either 'Y', 'y', 'N', or 'n'.
  347.  
  348.                       The default is R=N.  In this mode, once the
  349.                       timeout period expires the keys are sent.  After
  350.                       those keys are sent, LogOut must be run from the
  351.                       command line again to reset the timer and
  352.                       reenable the sending of keys.
  353.  
  354.                       With R=Y, the keys will be sent after the first
  355.                       timeout as above.  However, if the time period
  356.                       expires again and there is still no activity, the
  357.                       keys will be sent again.  If the user resumes
  358.                       working without running LogOut from the command
  359.                       line, then leaves the system inactive again, the
  360.                       keys will be sent after the next timeout occurs.
  361.  
  362.                       Repeat mode is intended for use as a continuous
  363.                       event.  For example, LogOut could save work in a
  364.                       word processor, spreadsheet or database each time
  365.                       the user pauses to think for longer than the time
  366.                       period, providing a useful automatic save feature
  367.                       for programs which do not already have one.
  368.  
  369.  
  370.  
  371.         The Immediate Mode                                       Page 7
  372.         ───────────────────────────────────────────────────────────────
  373.  
  374.  
  375.                       LO [?] [T=mmm] [F=filename.ext] [C=ID] [R=x]
  376.  
  377.                        ┌──────────┐
  378.                        │ [I=(yn)] │ [N=device] [X=device] [?]
  379.                        └──────────┘
  380.  
  381.  
  382.                       The immediate mode tells LogOut to send the keys
  383.                       immediately, without waiting for the time limit
  384.                       to expire.
  385.  
  386.                       The default is I=N, for no immediate send of
  387.                       keys.  If I=Y is entered, then the keys will be
  388.                       sent immediately - probably before LogOut even
  389.                       finishes running!  The keys will be waiting there
  390.                       for whatever program first reads the keyboard.
  391.                       That may be DOS, or a menu program, or
  392.                       practically anything else.
  393.  
  394.                       Be aware that many programs clear the keyboard
  395.                       buffer before reading the keyboard.  This is a
  396.                       safety measure on their part.  In these cases,
  397.                       the keys LogOut immediately sent will be cleared
  398.                       out and will appear to have not been sent.
  399.                       Experimentation will detect this.
  400.  
  401.  
  402.  
  403.         The Include and Exclude Device Lists                     Page 8
  404.         ───────────────────────────────────────────────────────────────
  405.  
  406.  
  407.                       LO [?] [T=mmm] [F=filename.ext] [C=ID] [R=x]
  408.  
  409.                                   ┌───────────────────────┐
  410.                          [I=(yn)] │ [N=device] [X=device] │ [?]
  411.                                   └───────────────────────┘
  412.  
  413.  
  414.                       The include and exclude device lists are used to
  415.                       tell LogOut to include or exclude particular
  416.                       devices from being watched for activity.
  417.  
  418.                       The device list may contain D, K, P and S for
  419.                       disk, keyboard, printer and screen watching
  420.                       respectively.
  421.  
  422.                       It is important to know the order that the
  423.                       devices are processed.  First, the excluded
  424.                       devices are set up, then the included devices are
  425.                       set up.  This means that if the same device is
  426.                       specified as both included and excluded, it will
  427.                       end up being included in the devices being
  428.                       watched for activity.
  429.  
  430.                       The default is N=DKPS, so all supported devices
  431.                       are watched.
  432.  
  433.                       Some programs run for a long time, like menu
  434.                       systems, and they may do things like keep a clock
  435.                       on the screen, or write a log file occasionally.
  436.                       To allow LogOut to detect that the system is
  437.                       inactive in these situations, it may be necessary
  438.                       to exclude the active device from watching.
  439.  
  440.                       The exclude feature should be used with caution.
  441.                       It is possible for database programs, for
  442.                       example, to work on an update for a long period
  443.                       of time.  It could be disastrous for LogOut to
  444.                       attempt to exit the program during such a
  445.                       process, but if disk and screen watching were
  446.                       turned off that could very well happen!  The
  447.                       ultimate responsibility rests with the person who
  448.                       runs LogOut.  It can only do as it is told.
  449.  
  450.                       The include feature allows including devices that
  451.                       were excluded in previous runs.
  452.  
  453.                       If N and X are used frequently, it is safest to
  454.                       use them on every run to explicitly state on each
  455.                       run what is to be included or excluded, rather
  456.                       than rely on the order of runs to maintain the
  457.                       included and excluded device lists.
  458.  
  459.  
  460.  
  461.         Combinations of Parameters                               Page 9
  462.         ───────────────────────────────────────────────────────────────
  463.  
  464.  
  465.                               Combining F=filename.ext and C=ID
  466.  
  467.                       The F and C parameters should be used as a pair
  468.                       unless the default value is to be used for the
  469.                       unused parameter.
  470.  
  471.                       For example, if C is used and not F, then LogOut
  472.                       will look for the supplied current keystroke ID
  473.                       in the default keystroke file "LOGOUT.DAT".
  474.  
  475.                       Conversely, if F is used and not C, LogOut will
  476.                       look in the supplied keystroke file for the
  477.                       default current keystroke ID "DEF".
  478.  
  479.  
  480.                             Combining T=mmm, I=(yn) and R=(yn)
  481.  
  482.                       Entering I=Y will result in an immediate send of
  483.                       keystrokes, unless T=0 is entered on the same run
  484.                       to disable LogOut altogether.
  485.  
  486.                       Subsequent sending of keystrokes depends on the
  487.                       R=(yn) parameter.  If R=Y was entered on the same
  488.                       run, then the keystrokes will be sent again upon
  489.                       each timeout, as specified by the T=mmm
  490.                       parameter.  But, if R=N was entered instead, the
  491.                       T=mmm parameter will be ignored and keys will not
  492.                       be sent again after the immediate send.  The
  493.                       immediate send is the only send in that case.
  494.  
  495.  
  496.                                Combining N=device and X=device
  497.  
  498.                       The excluded devices are evaluated first, then
  499.                       the included devices.  So, if a device is
  500.                       specified as both included and excluded, it will
  501.                       end up being included when LogOut is finished
  502.                       with the run.  This was deemed the safest
  503.                       behavior, and more convenient than ending with an
  504.                       error.
  505.  
  506.  
  507.                             Combining T=0 with any other parameter
  508.  
  509.                       If T=0 is specified to disable LogOut, any other
  510.                       parameters specified at the same time are still
  511.                       evaluated.  They will be set just as they were
  512.                       entered, except that LogOut will not act on them
  513.                       because it is disabled.  If enabled with T=mmm
  514.                       other than '0', then the parameters will already
  515.                       be set to the earlier state.
  516.  
  517.  
  518.  
  519.         Keystroke File Structure                                Page 10
  520.         ───────────────────────────────────────────────────────────────
  521.  
  522.  
  523.                       Each line of the keystroke file has the following
  524.                       structure:
  525.  
  526.                            ID=aaa,sss,[aaa,sss,aaa,sss,...],255
  527.  
  528.                       The "ID" terms are unique keystroke IDs that
  529.                       identify a keystroke sequence.
  530.  
  531.                       The "aaa,sss" terms are the ASCII code, scan code
  532.                       pair for each key in a keystroke sequence.  The
  533.                       required '255' marks the end of a line of key
  534.                       codes.  The ID is separated from the key codes by
  535.                       the equal ('=') sign and the keycodes are
  536.                       separated from each other by commas.  A maximum
  537.                       of 15 characters may be sent by LogOut, so this
  538.                       adds up to 30 codes.  Then there is the '255', so
  539.                       the total number of codes after the equal sign is
  540.                       31.  The codes may be less than three digits.
  541.  
  542.                       The utility program KEYS.EXE has been provided to
  543.                       enable any key code to be found.  KEYS will show
  544.                       the key and the ASCII code and scan code for the
  545.                       key.  Type a <Ctrl-Break> to exit from KEYS.  The
  546.                       codes returned are the ones that must be put in
  547.                       the keystroke file.  Each key that is to be sent
  548.                       consists of these two codes.  It is the
  549.                       responsibility of the person who maintains the
  550.                       keystroke file to enter the correct codes, LogOut will
  551.                       send exactly what is entered.
  552.  
  553.                       Hint: use <Ctrl-PrtSc> to print the codes on the
  554.                       printer.  Or, use redirection ('|' or '>' or '>>'
  555.                       on the command line - see your DOS manual) to
  556.                       send the codes to the printer or to a file.
  557.  
  558.                       A sample keystroke file is shown in appendix A, and in
  559.                       the file LOGOUT.DAT supplied with this program.
  560.                       If you intend to use comments in the keystroke file,
  561.                       then imitate the ones in the sample file.
  562.  
  563.                       By keeping the data in a plain ASCII text file
  564.                       the user can control exactly what LogOut will do
  565.                       when the timeout period is reached, either save
  566.                       or not save work in progress, beep instead of
  567.                       exit, or even execute a program from the DOS
  568.                       prompt.
  569.  
  570.  
  571.  
  572.         General Hints                                           Page 11
  573.         ───────────────────────────────────────────────────────────────
  574.  
  575.  
  576.                                      'Sticky' Parameters
  577.  
  578.                       The parameters used by LogOut remain set in their
  579.                       current state until explicitly changed.  If, for
  580.                       example, X=D is entered to exclude disk activity
  581.                       watching, then disk activity watching will remain
  582.                       excluded until explicitly included. The only
  583.                       exception is if LogOut is disabled with T=0.  If
  584.                       a subsequent run does not specify a time limit,
  585.                       the time will automatically be set to the default
  586.                       30 minutes.
  587.  
  588.  
  589.                                     Efficient Memory Usage
  590.  
  591.                       It is best to load this and all other memory
  592.                       resident programs with as small an environment as
  593.                       possible.  A copy of the environment is loaded
  594.                       with each TSR, and on some machines that can be
  595.                       quite a lot of space.
  596.  
  597.                       For TSRs loaded from AUTOEXEC.BAT, this is easy,
  598.                       just load the TSRs before setting any environment
  599.                       variables (the lines containing the SET command:
  600.                       SET somename=something).  After the TSRs are
  601.                       loaded, then set the environment.
  602.  
  603.                       LogOut facilitates this by allowing itself to be
  604.                       loaded in its disabled state, with the T=0
  605.                       parameter.  This way, LogOut can be loaded early
  606.                       and have no effect until it is needed.  It takes
  607.                       up such a small space this way, less than 1024
  608.                       bytes, that it is unlikely to cause an out-of-
  609.                       memory condition by itself.  And, if the machine
  610.                       is out of memory with LogOut installed, it will
  611.                       almost surely still be out of memory if only
  612.                       LogOut is removed.  It is so small that it just
  613.                       doesn't make much difference in memory if it is
  614.                       installed or not.
  615.  
  616.  
  617.                                        User Suggestions
  618.  
  619.                       If LogOut does not perform as described here, or
  620.                       if you have a unique requirement, please notify
  621.                       Byte_Magic Software.  All requests for increased
  622.                       functionality will be entertained, most can be
  623.                       accommodated.  Bug fixes are handled on an
  624.                       emergency basis - I don't want my programs 'out
  625.                       there' creating havoc.
  626.  
  627.  
  628.  
  629.  
  630.  
  631.         Technical Information                                   Page 12
  632.         ───────────────────────────────────────────────────────────────
  633.  
  634.  
  635.                       The LogOut program is divided into two distinct
  636.                       parts, the resident part and the initialization
  637.                       part.  The LogOut initialization code has the
  638.                       following functions:
  639.  
  640.                            * Check for an already installed copy of the
  641.                              LogOut program by looking for the known
  642.                              interrupt 61h code.
  643.  
  644.                            * If not already installed, redirect the 61h
  645.                              interrupt vector and chain into the 09h,
  646.                              10h, 13h, 17h and 1Ch interrupt vectors.
  647.                              These are the user, keyboard, screen,
  648.                              disk, printer and timer interrupts
  649.                              respectively.
  650.  
  651.                            * Handle the command line arguments, i.e.
  652.                              load the correct keystroke file, send the
  653.                              keystroke codes to the resident part, etc.
  654.                              Not all of these tasks are done for each
  655.                              run.  Changing the time limit, for
  656.                              example, does not require reading the
  657.                              keystroke file or changing the keystrokes.
  658.                              If no arguments are present or there is an
  659.                              error in one of them, disable LogOut and
  660.                              display an appropriate error message.
  661.  
  662.                            * If being installed on this run, terminate
  663.                              and stay resident, leaving only the
  664.                              resident code in memory.  Otherwise, just
  665.                              terminate normally.
  666.  
  667.                       Subsequent runs of LogOut, after the first run,
  668.                       merely alter the resident code that was installed
  669.                       on the first run.
  670.  
  671.  
  672.  
  673.         Technical Information (continued)                       Page 13
  674.         ───────────────────────────────────────────────────────────────
  675.  
  676.  
  677.                       The resident code is the set of above-mentioned
  678.                       interrupt handlers.  The interrupt 09h, 10h, 13h,
  679.                       and 17h handlers, if not excluded with the 'X'
  680.                       command line parameter, simply reset the elapsed
  681.                       time counter to zero each time a key is pressed,
  682.                       or the screen is updated, or a disk drive is
  683.                       accessed, or the printer is used.
  684.  
  685.                       The timer interrupt handler (1Ch) is used to keep
  686.                       track of elapsed time since the last activity.
  687.                       It also sends the key codes to the keyboard
  688.                       buffer area in memory if the time limit is
  689.                       exceeded (as long as LogOut has not been
  690.                       disabled).
  691.  
  692.                       The user interrupt (61h) handler is used to
  693.                       communicate between the resident and non-resident
  694.                       parts of LogOut.  It is one of several interrupts
  695.                       defined by IBM as user interrupts and is unused
  696.                       by nearly all software.  In LogOut, this
  697.                       interrupt performs thirteen different services,
  698.                       selected by the value in the AH register when
  699.                       called.  These services are shown in appendix B.
  700.                       Any other program can be written to use these
  701.                       interrupt 61h services provided LogOut is
  702.                       installed first.
  703.  
  704.                       The interrupt 61h handler DOES NOT chain to a
  705.                       previously installed handler.  LogOut will not
  706.                       install itself if this interrupt is already being
  707.                       used.  This is because there is no documented way
  708.                       for this interrupt to be cooperatively used.
  709.                       With no existing guidelines for cooperation, it
  710.                       would be very unlikely that LogOut and another
  711.                       program could work in harmony.
  712.  
  713.                       LogOut's interrupt 61h services are listed in
  714.                       appendix B so that other programmers can
  715.                       use them if desired.  LogOut would need to be
  716.                       loaded ahead of any other software that is
  717.                       written to use these services.  Interrupt 61h
  718.                       services above AH=13 are ignored by this version
  719.                       of LogOut, so additional capabilities can be
  720.                       implemented as higher numbered services without
  721.                       conflict.  Function numbers higher than about
  722.                       150 are recommended for compatibility with future
  723.                       versions.  LogOut continues to gain in
  724.                       functionality, and each new function needs a new
  725.                       function number for the interrupt 61h
  726.                       communication service.  Function numbers will be
  727.                       implemented in sequence, but the need for numbers
  728.                       above 150 is doubtful in this interrupt handler.
  729.  
  730.  
  731.  
  732.         Sample Keystroke File                                Appendix A
  733.         ───────────────────────────────────────────────────────────────
  734.             ;LOGOUT.DAT__LOGOUT_KEYSTROKE_FILE
  735.             DEF=7,34,255
  736.             BEEP=7,34,255
  737.             BEEPBEEP=7,34,7,34,255
  738.             DTP=27,1,0,79,0,79,0,79,255
  739.             EM=0,60,81,16,13,28,0,79,0,79,0,79,255
  740.             GT=27,1,27,1,27,1,27,1,0,79,0,79,0,79,255
  741.             HT=27,1,70,33,0,79,0,79,0,79,255
  742.             MT=27,1,27,1,27,1,0,79,0,79,0,79,255
  743.             PFS=27,1,27,1,27,1,27,1,69,18,89,21,0,79,0,79,0,79,255
  744.             WP=0,68,13,28,89,21,0,65,78,49,89,21,0,79,0,79,0,79,255
  745.             Q_SAVE=0,33,83,31,255
  746.             PCWRITE_SAVE=0,59,0,61,255
  747.             ;DEF=DEFAULT
  748.             ;BEEP=BEEP_ONCE
  749.             ;BEEPBEEP=BEEP_TWICE
  750.             ;DTP=DESKTOP_PUBLISHING
  751.             ;EM=E-MAIL
  752.             ;GT=GTAM
  753.             ;HT=HURRICANE_TRACKER
  754.             ;MT=MASTER_TYPE
  755.             ;PFS=PFS_PROFESSIONAL_WRITE_AND_FILE
  756.             ;WP=WORDPERFECT=WP
  757.             ;Q_SAVE=QEDIT_AUTOSAVE
  758.             ;PCWRITE_SAVE=PCWRITE_AUTOSAVE
  759.  
  760.  
  761.  
  762.         Interrupt 61h Services                               Appendix B
  763.         ───────────────────────────────────────────────────────────────
  764.  
  765.  
  766.             AH        SERVICE
  767.             ──        ─────────────────────────────────────────────────
  768.  
  769.             00        Does nothing.  May be used by another version of
  770.                       LogOut in the future.
  771.  
  772.             01        Returns the segment and offset of the storage
  773.                       area for the keys' ASCII and scan code pairs.
  774.                       SEGMENT:OFFSET returned in DX:AX.  (Note: this is
  775.                       changed from previous versions which used AX:DX -
  776.                       an abnormal register usage.)
  777.  
  778.             02        Changes the TIME_PERIOD.  The DX register must
  779.                       contain the new Time limit as input.
  780.  
  781.             03        Returns the current TIME_PERIOD in AX.
  782.  
  783.             04        Temporarily disables LogOut until a new
  784.                       TIME_PERIOD is set.  Puts 0 in TIME_PERIOD also.
  785.  
  786.             05        Returns 6161h in AX to indicate that this is the
  787.                       right interrupt 61h for LogOut.  This service is
  788.                       simply an identification service.  A return value
  789.                       of other than 6161h signals that interrupt 61h is
  790.                       being used by another program.
  791.  
  792.             06        Sets the REPEAT_FLAG.  The DL register must
  793.                       contain 1 to set Repeat mode ON, and 0 to set
  794.                       Repeat mode OFF.
  795.  
  796.             07        Returns the REPEAT_FLAG, repeat mode setting, in
  797.                       the AL register.
  798.  
  799.             08        Sets the IMMEDIATE_FLAG.  The DL register must
  800.                       contain 1 to set Immediate mode ON, and 0 to set
  801.                       Immediate mode OFF.
  802.  
  803.             09        Returns the IMMEDIATE_FLAG, immediate mode setting,
  804.                       in the AL register.
  805.  
  806.             10        Enable/disable disk watching.  The DL register must
  807.                       contain 1 to enable watching, 0 to disable watching.
  808.  
  809.             11        Enable/disable keyboard checking.  The DL register must
  810.                       contain 1 to enable watching, 0 to disable watching.
  811.  
  812.             12        Enable/disable printer checking.  The DL register must
  813.                       contain 1 to enable watching, 0 to disable watching.
  814.  
  815.             13        Enable/disable screen checking.  The DL register must
  816.                       contain 1 to enable watching, 0 to disable watching.
  817.  
  818.             14-255    Does nothing in LogOut as of v1.71.
  819.  
  820.  
  821.  
  822.         Packing List                                         Appendix C
  823.         ───────────────────────────────────────────────────────────────
  824.  
  825.  
  826.                        LogOut is sent in the following archive:
  827.  
  828.               LO171.ZIP .... LogOut archive file
  829.  
  830.  
  831.                       The archive includes the following files:
  832.  
  833.               LO.COM ....... LogOut executable program.
  834.  
  835.               LO171.DOC .... This file - documentation for LogOut v1.71.
  836.  
  837.               LOGOUT.DAT ... Sample keystroke file, can be used as is
  838.                              or as a stable starting point.
  839.  
  840.               KEYS.EXE ..... Utility program to show key codes to use
  841.                              for keystrokes in the keystroke file.
  842.  
  843.  
  844.               If these files were not all there upon extraction of the
  845.               archive, please notify the source of the LogOut archive
  846.               that their copy is not valid and cannot be supported by
  847.               Byte_Magic Software, the original author of the program.
  848.               Also, please notify Byte_Magic Software so that a
  849.               complete copy can be supplied.
  850.  
  851.  
  852.  
  853.            LL         OOOOOO    GGGGGG    OOOOOO   UU    UU  TTTTTTTT
  854.            LL        OO    OO  GG    GG  OO    OO  UU    UU     TT
  855.            LL        OO    OO  GG        OO    OO  UU    UU     TT
  856.            LL        OO    OO  GG        OO    OO  UU    UU     TT
  857.            LL        OO    OO  GG  GGGG  OO    OO  UU    UU     TT
  858.            LL    LL  OO    OO  GG    GG  OO    OO  UU    UU     TT
  859.            LLLLLLLL   OOOOOO    GGGGGG    OOOOOO    UUUUUU      TT
  860.  
  861.  
  862.        Copyright (c) 1988-1990 Byte_Magic Software.  All rights reserved.
  863.  
  864.  
  865.                                   Version 1.71
  866.  
  867.  
  868.  
  869.  
  870.                                   Greg Messer
  871.  
  872.                               Byte_Magic Software
  873.  
  874.                             9850 Meadowglen Ln.  #35
  875.  
  876.                              Houston, Texas  77042
  877.  
  878.                                 (713) 975-9033
  879.  
  880.  
  881.  
  882. This is version is freeware - copyright, but you may freely use it for your
  883. personal use.
  884.  
  885.    Distributed by Public (software) Library with permission of the author.
  886.  
  887.                            Public (software) Library
  888.                                P.O.Box 35705 - F
  889.                             Houston, TX 77235-5705
  890.  
  891.          For a copy of the latest monthly software library newsletter
  892.          and a list of the 2,500+ disks in the library, call or write
  893.  
  894.                                  Orders Only:
  895.                                 1-800-2424-PSL
  896.                               FAX: 713-524-6398
  897.                             CompuServe: 71355,470
  898.                             MC/Visa/AmEx/Discover
  899.  
  900.                           Outside of U.S. or in Texas
  901.                           or for general information,
  902.                               Call 1-713-524-6394
  903.  
  904.                           PsL also has an outstanding
  905.                           catalog for the Macintosh.
  906.  
  907.